﻿<%@ Page Language="C#" MasterPageFile="~/Org/MasterPage.master" AutoEventWireup="true"
    ValidateRequest="false" CodeFile="frmO_EmpRewPunInput.aspx.cs" Inherits="Org_frmO_EmpRewPunInput"
    Culture="ja-JP" UICulture="ja" Title="賞罰情報登録" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="Server">
    賞罰情報登録
</asp:Content>

<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="Server">

        <script type="text/javascript" language="javascript" src="../js/jquery.min.js">
        </script>
        <script language="javascript" type="text/javascript" src="../js/Validation.js"></script>
        <script language="javascript" type="text/javascript" src="../js/jquery.maxlength.js"></script>
        

        <script type="text/javascript">
            $(document).ready(function() {

                $('#<%=txt_賞罰特記事項.ClientID %>').maxlength({
                    events: [], // Array of events to be triggerd    
                    maxCharacters: 1000, // Characters limit   
                    status: false, // True to show status indicator bewlow the element    
                    showAlert: false, // True to show a regular alert message    
                    slider: false // True Use counter slider    
                });

                $('#<%= txt_賞罰名.ClientID %>').keydown(function(e) {
                    if (e.which == 13)
                    { e.preventDefault(); $('#<%= txt_賞罰年月日.ClientID %>').focus(); }
                });
                $('#<%= txt_賞罰年月日.ClientID %>').keydown(function(e) {
                    if (e.which == 13)
                    { e.preventDefault(); $('#<%= txt_賞罰特記事項.ClientID %>').focus(); }
                });

                registerEnterEvent("enter", "<%= btn登録.ClientID %>", 3);
                registerControlToValidation("validation");
                formatDate("css_text_calender", "/");

            });

        </script>

    <div class="maindiv1">
    <link href="../Style/Style.css" rel="stylesheet" type="text/css" />
        <div class="Header1">
            <span>＊: 必須</span>
        </div>
        
        <div class="NoteStyle">
            <span>※下記の情報があれば、必須項目を入力してください。なければ、次ボタンを押してください。 </span>
        </div>
        <div>
            &nbsp;</div>
        <div class="detail-admin-row">
        </div>
        <div class="detail-admin-row">
            <span class="detail-admin-label">賞罰名 :</span>
            <asp:TextBox ID="txt_賞罰名" runat="server" Font-Names="MS UI Gothic" MaxLength="100"
                ValidationGroup="detailform" CssClass="enter validation textbox width2"></asp:TextBox>
            <span class="required-field">*</span>
            <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" Font-Names="MS UI Gothic"
                ErrorMessage="" ControlToValidate="txt_賞罰名" Display="None" SetFocusOnError="False"></asp:RequiredFieldValidator>
            <ajaxToolkit:ValidatorCalloutExtender runat="Server" ID="ValidatorCalloutExtender11" Width="260px"
                TargetControlID="RequiredFieldValidator1" HighlightCssClass="invalid" CssClass="CustomValidatorCalloutStyle"
                WarningIconImageUrl="../Images/warning.png" />
        </div>
        <div class="detail-admin-row">
            <span class="detail-admin-label">賞罰年月日 :</span>
            <asp:TextBox ID="txt_賞罰年月日" runat="server" Font-Names="MS UI Gothic" ValidationGroup="detailform"
                onkeypress="return InputNumberKeys(this, event)" Style="ime-mode: disabled" CssClass="enter validation css_text_calender textbox width_calendar"></asp:TextBox>
            <asp:ImageButton ID="ImageButton2" runat="server" ImageUrl="../Images/calendar.jpg"
                Height="16px" CssClass="cal_Img" CausesValidation="False" ValidationGroup="detailform" />
            <span class="required-field">*</span>
            <ajaxToolkit:CalendarExtender ID="CalendarExtender2" runat="server" PopupButtonID="ImageButton2"
                TargetControlID="txt_賞罰年月日" Format="yyyy/MM/dd">
            </ajaxToolkit:CalendarExtender>
            <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" ControlToValidate="txt_賞罰年月日"
                ErrorMessage="" Display="None" SetFocusOnError="false"></asp:RequiredFieldValidator>
            <%--<asp:CustomValidator ID="CustomValidator1" runat="server" 
                ControlToValidate="txt_賞罰年月日" ErrorMessage="Customer1" Display="None" SetFocusOnError="False" ClientValidationFunction="checkDateNull">
            </asp:CustomValidator>--%>
            <ajaxToolkit:ValidatorCalloutExtender runat="Server" ID="ValidatorCalloutExtender2" Width="260px"
                TargetControlID="RequiredFieldValidator2" HighlightCssClass="invalid" CssClass="CustomValidatorCalloutStyle"
                WarningIconImageUrl="../Images/warning.png" />
            <%--<asp:RegularExpressionValidator runat="server" Display="None" ID="RegularExpressionValidator1"
                ControlToValidate="txt_賞罰年月日" ValidationExpression="^((((19|20)(([02468][048])|([13579][26]))[- /.]02[- /.]29))|((20[0-9][0-9])|(19[0-9][0-9]))[- /.]((((0[1-9])|(1[0-2]))[-  /.]((0[1-9])|(1\d)|(2[0-8])))|((((0[13578])|(1[02]))[- /.]31)|(((0[1,3-9])|(1[0-2]))[- /.](29|30)))))$"
                ErrorMessage="" SetFocusOnError="False"></asp:RegularExpressionValidator>--%>
            <asp:CustomValidator ID="RegularExpressionValidator1" runat="server" ControlToValidate="txt_賞罰年月日"
                ErrorMessage="Customer1" Display="None" SetFocusOnError="False" ClientValidationFunction="isDate">
            </asp:CustomValidator>
            <ajaxToolkit:ValidatorCalloutExtender runat="Server" ID="ValidatorCalloutExtender1" Width="240px"
                TargetControlID="RegularExpressionValidator1" HighlightCssClass="invalid" CssClass="CustomValidatorCalloutStyle"
                WarningIconImageUrl="../Images/warning.png" />
        </div>
        <div class="detail-admin-row">
            <span class="detail-admin-label">賞罰特記事項 :</span>
            <asp:TextBox ID="txt_賞罰特記事項" runat="server" Font-Names="MS UI Gothic" TextMode="MultiLine"
                CssClass="textarea enter validation" Style="ime-mode: active" ValidationGroup="detailform"></asp:TextBox>
            <span class="required-field">*</span>
            <asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" Font-Names="MS UI Gothic"
                ErrorMessage="" ControlToValidate="txt_賞罰特記事項" Display="None" SetFocusOnError="False"></asp:RequiredFieldValidator>
            <ajaxToolkit:ValidatorCalloutExtender runat="Server" ID="ValidatorCalloutExtender3" Width="260px"
                TargetControlID="RequiredFieldValidator3" HighlightCssClass="invalid" CssClass="CustomValidatorCalloutStyle"
                WarningIconImageUrl="../Images/warning.png" />
        </div>
        <br />
        <div class="detail-admin-row">
            <span class="detail-admin-label">&nbsp;</span>
            <asp:Button ID="btn登録" runat="server" Text="登録" CssClass="btn" OnClick="btn登録_Click"
                OnClientClick="javascript:focusToControlErr();" />
            &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
            <asp:Button ID="btnリセット" runat="server" Text="リセット" CssClass="btn" OnClick="btnリセット_Click"
                CausesValidation="False" />
        </div>
    </div>
    <div class="detail-admin-row">
        <div class="btn_back">
            <asp:Button ID="btn_戻る" runat="server" Text="←戻る" OnClick="btn_戻る_Click" 
                CssClass="btn" CausesValidation="False" />
        </div>
        <div class="btn_next">
            <asp:Button ID="btn_次" runat="server" Text="次→" OnClick="btn_次_Click" 
                CssClass="btn" CausesValidation="False" />
        </div>
    </div>
    <div>
        &nbsp;</div>
    <br />
    <%--<div>
        &nbsp;</div>
    <br />
    <asp:UpdatePanel ID="UpdatePanel1" runat="server">
        <Triggers>
            <asp:AsyncPostBackTrigger ControlID="btn登録" EventName="Click" />
        </Triggers>
    </asp:UpdatePanel>--%>
</asp:Content>